// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .cs}

//-------------MAIN---------------
thread 'FORC' 


//:START
WHILE TRUE
    REPEAT
    WAIT 0
    UNTIL IF PLAYER.Defined(0)
    if 
         Actor.Driving($PLAYER_ACTOR)
    THEN
        IF
            847A:   not actor $PLAYER_ACTOR driving_bike 
        THEN
            2@ = 0 
            0209: 0@ = random_int_in_ranges 105 107
            Model.Load(0@)
            Model.Load(#rocketla)
            Model.Load(#ak47)
            038B: load_requested_models
            
            :loopq
            wait 0
            if and
               Model.Available(0@)
               Model.Available(#rocketla)
               Model.Available(#ak47)
            then
                else
                goto @loopq
            end
            
            26@ = Actor.CurrentCar($PLAYER_ACTOR)
            car.SetImmunities(26@, 1, 1, 1, 1, 1)
            21@ = Actor.Create(8, 0@, 0.0, 0.0, 0.0)
            20@ = Actor.Create(8, 0@, 0.0, 0.0, 0.0)
            19@ = Actor.Create(8, 0@, 0.0, 0.0, 0.0)
            18@ = Actor.Create(8, 0@, 0.0, 0.0, 0.0)
            07DD: set_actor 21@ attack_rate 100 // previously known as temper_to 
            07DD: set_actor 20@ attack_rate 100 // previously known as temper_to 
            07DD: set_actor 19@ attack_rate 100 // previously known as temper_to 
            07DD: set_actor 18@ attack_rate 100 // previously known as temper_to 
            Actor.WeaponAccuracy(21@) = 95
            Actor.WeaponAccuracy(20@) = 95
            Actor.WeaponAccuracy(19@) = 95
            Actor.WeaponAccuracy(18@) = 95
            Actor.SetImmunities(21@, 1, 1, 1, 1, 1)
            Actor.SetImmunities(20@, 1, 1, 1, 1, 1)
            Actor.SetImmunities(19@, 1, 1, 1, 1, 1)
            Actor.SetImmunities(18@, 1, 1, 1, 1, 1)
            wait 50 
            06A7: put_actor 21@ into_turret_on_car 26@ at_car_offset 1.0 -2.0 1.0 position 1 shooting_angle 360.0 360.0 with_weapon 30
            06A7: put_actor 20@ into_turret_on_car 26@ at_car_offset -1.0 -2.0 1.0 position 1 shooting_angle 360.0 360.0 with_weapon 30
            06A7: put_actor 19@ into_turret_on_car 26@ at_car_offset 1.0 -1.0 1.0 position 1 shooting_angle 360.0 360.0 with_weapon 35
            06A7: put_actor 18@ into_turret_on_car 26@ at_car_offset -1.0 -1.0 1.0 position 1 shooting_angle 360.0 360.0 with_weapon 35
            0638: AS_actor 21@ stay_put 1
            0638: AS_actor 20@ stay_put 1
            0638: AS_actor 19@ stay_put 1
            0638: AS_actor 18@ stay_put 1
            0337: set_actor 21@ visibility 1 
            0337: set_actor 20@ visibility 1 
            0337: set_actor 19@ visibility 1 
            0337: set_actor 18@ visibility 1 
            FOR 1@ = 17 TO 30 STEP 1
                077A: set_actor 21@ acquaintance 4 to_actors_pedtype 1@ // see ped.dat
                077A: set_actor 20@ acquaintance 4 to_actors_pedtype 1@ // see ped.dat
                077A: set_actor 19@ acquaintance 4 to_actors_pedtype 1@ // see ped.dat
                077A: set_actor 18@ acquaintance 4 to_actors_pedtype 1@ // see ped.dat
                2@ += 1
                if 2@ > 6
                then
                    2@ = 0
                end 
                092B: 3@ = group $PLAYER_GROUP member 2@ 
                if 056D:   actor 3@ defined
                then
                    wait 10
                    1@ += 1
                    if 1@ > 30
                    then
                        1@ = 17
                    end 
                    077A: set_actor 3@ acquaintance 4 to_actors_pedtype 1@ // see ped.dat
                    Actor.SetImmunities(3@, 1, 1, 1, 1, 1)
                    Actor.WeaponAccuracy(3@) = 95
                    07DD: set_actor 3@ attack_rate 100 // previously known as temper_to
                    Actor.GiveWeaponAndAmmo(3@, 30, 99999)
                end
            end
         
            REPEAT
            WAIT 0
            0AF0: 5@ = get_int_from_ini_file "CLEO\POZIT.INI" section "GUR" key "GET" 
            UNTIL IF  5@ == 1    
            if and
                056D:   actor 21@ defined 
                056D:   actor 20@ defined 
                056D:   actor 19@ defined 
                056D:   actor 18@ defined 
            THEN
                Actor.RemoveReferences(21@)
                Actor.DestroyInstantly(21@)
                Actor.RemoveReferences(20@)
                Actor.DestroyInstantly(20@)
                Actor.RemoveReferences(19@)
                Actor.DestroyInstantly(19@)
                Actor.RemoveReferences(18@)
                Actor.DestroyInstantly(18@)
            END 
            end_thread
        END     
    END         
END